/***********************************
 *           3/24/2014             *
 *       by Meow dev (arm genesis) *
 *                                 *
 ***********************************/
package com.meow.dev.engine;
import com.sun.jna.Library;
import com.sun.jna.Native;
import com.sun.jna.NativeLong;
import com.sun.jna.ptr.LongByReference;
import com.sun.jna.ptr.NativeLongByReference;


public interface FKAttendDLLMapping extends Library {

	FKAttendDLLMapping INSTANCE = (FKAttendDLLMapping) Native.loadLibrary("FKAttend", FKAttendDLLMapping.class);
			 
//	long FK_ConnectNet(long nMachineNo, char * pstrIpAddress, long nNetPort, long nTimeOut, long nProtocolType, long nNetPassword, long nLicense) 
	NativeLong FK_ConnectNet(NativeLong nMachineNo, String pstrIpAddress, NativeLong nNetPort, NativeLong nTimeOut, NativeLong nProtocolType, NativeLong nNetPassword, NativeLong nLicense); 
	
	void FK_DisConnect(NativeLong nHandleIndex);
	
//	long FK_GetDeviceVersion(long nHandleIndex, long *pnVersion)
	NativeLong FK_GetDeviceVersion(NativeLong nHandleIndex, NativeLongByReference pnVersion);
	
	
//     ************ for Enroll Data *************	
//	   ******************************************
//	long FK_ReadAllUserID(long nHandleIndex)
	NativeLong FK_ReadAllUserID(NativeLong nHandleIndex);
//	long FK_GetAllUserID(long nHandleIndex, long * pnEnrollNumber, long * pnBackupNumber, long * pnMachinePrivilege, long * pnEnableFlag) 
	NativeLong FK_GetAllUserID(NativeLong nHandleIndex, LongByReference pnEnrollNumber, LongByReference pnBackupNumber, LongByReference pnMachinePrivilege, LongByReference pnEnableFlag) ;
//	long FK_DeleteEnrollData(long nHandleIndex, long nEnrollNumber, long nBackupNumber) 
	NativeLong FK_DeleteEnrollData(NativeLong nHandleIndex, NativeLong nEnrollNumber, NativeLong nBackupNumber); 
//	long FK_EmptyEnrollData(long nHandleIndex)
	NativeLong FK_EmptyEnrollData(NativeLong nHandleIndex);
//	long FK_BenumbAllManager(long nHandleIndex)
	NativeLong FK_BenumbAllManager(NativeLong nHandleIndex);
//	long FK_GetEnrollData(long nHandleIndex, long nEnrollNumber, long 
//	nBackupNumber, long * pnMachinePrivilege, void * pnEnrollData, long * pnPassWord)
	NativeLong FK_GetEnrollData(NativeLong nHandleIndex, NativeLong nEnrollNumber, NativeLong nBackupNumber,
			NativeLongByReference pnMachinePrivilege, long[]  fingerData, NativeLongByReference passWordAndCard);
	
//	************* add new USER **************
//	long FK_PutEnrollData(long nHandleIndex, long nEnrollNumber, long 
//			nBackupNumber, long nMachinePrivilege, void * pnEnrollData, long nPassWord)
	NativeLong FK_PutEnrollData(NativeLong nHandleIndex, NativeLong nEnrollNumber, NativeLong 
			nBackupNumber, NativeLong nMachinePrivilege, long[] pnEnrollData, NativeLong nPassWord);
//	long FK_SaveEnrollData(long nHandleIndex) 
	NativeLong FK_SaveEnrollData(NativeLong nHandleIndex); 
//	long FK_PutEnrollDataWithString(long nHandleIndex, long nEnrollNumber, long 
//			nBackupNumber, long nMachinePrivilege, char *apstrEnrollData)
	NativeLong FK_PutEnrollDataWithString(NativeLong nHandleIndex, NativeLong nEnrollNumber, NativeLong 
			nBackupNumber, NativeLong nMachinePrivilege, String userName);
	
//	long FK_GetEnrollDataWithString(long nHandleIndex, long nEnrollNumber, long 
//			nBackupNumber, long * pnMachinePrivilege, LPSTR *apstrEnrollData)
	NativeLong FK_GetEnrollDataWithString(NativeLong nHandleIndex, NativeLong nEnrollNumber, NativeLong 
			nBackupNumber, LongByReference pnMachinePrivilege, byte[] apstrEnrollData);
	
//	****************** LOAD LOG ****************************
//	long FK_LoadGeneralLogData(long nHandleIndex, long nReadMark) 
	NativeLong FK_LoadGeneralLogData(NativeLong nHandleIndex, NativeLong nReadMark); 	
//	long FK_GetGeneralLogData_1(long nHandleIndex ,long *apnEnrollNumber, long 
//			pnVerifyMode , long *apnInOutMode, long *apnYear, long *apnMonth, long *apnDay, 
//			long *apnHour, long *apnMinute, long *apnSec )
	NativeLong FK_GetGeneralLogData_1(NativeLong nHandleIndex ,LongByReference apnEnrollNumber, 
			LongByReference pnVerifyMode , LongByReference apnInOutMode, LongByReference apnYear, LongByReference apnMonth, LongByReference apnDay, 
			LongByReference apnHour, LongByReference apnMinute, LongByReference apnSec );
	
	
	
// ******************************** DEVIEC ************************	
//	long FK_EnableDevice(long nHandleIndex, unsigned char nEnableFlag) 
	NativeLong FK_EnableDevice(NativeLong nHandleIndex, NativeLong nEnableFlag); 
//	long FK_ClearKeeperData(long nHandleIndex) 
//  reset 
	NativeLong FK_ClearKeeperData(NativeLong nHandleIndex) ;	
	
//Clear log
//	long FK_EmptyGeneralLogData(long nHandleIndex) ;
	NativeLong FK_EmptyGeneralLogData(NativeLong nHandleIndex) ;

}
